package co.com.inventarios.persistencia;

import java.util.List;

import co.com.inventarios.modelo.Mngtdc;
import co.com.inventarios.modelo.MngtdcId;

/**
 * Interface for MngtdcDAO.
 * 
 * @author MyEclipse Persistence Tools
 */

public interface IMngtdcDAO {
	/**
	 * Perform an initial save of a previously unsaved Mngtdc entity. All
	 * subsequent persist actions of this entity should use the #update()
	 * method. This operation must be performed within the a database
	 * transaction context for the entity's data to be permanently saved to the
	 * persistence store, i.e., database. This method uses the
	 * {@link javax.persistence.EntityManager#persist(Object) EntityManager#persist}
	 * operation.
	 * 
	 * <pre>
	 * EntityManagerHelper.beginTransaction();
	 * IMngtdcDAO.save(entity);
	 * EntityManagerHelper.commit();
	 * </pre>
	 * 
	 * @param entity
	 *            Mngtdc entity to persist
	 * @throws RuntimeException
	 *             when the operation fails
	 */
	public void save(Mngtdc entity);

	/**
	 * Delete a persistent Mngtdc entity. This operation must be performed
	 * within the a database transaction context for the entity's data to be
	 * permanently deleted from the persistence store, i.e., database. This
	 * method uses the
	 * {@link javax.persistence.EntityManager#remove(Object) EntityManager#delete}
	 * operation.
	 * 
	 * <pre>
	 * EntityManagerHelper.beginTransaction();
	 * IMngtdcDAO.delete(entity);
	 * EntityManagerHelper.commit();
	 * entity = null;
	 * </pre>
	 * 
	 * @param entity
	 *            Mngtdc entity to delete
	 * @throws RuntimeException
	 *             when the operation fails
	 */
	public void delete(Mngtdc entity);

	/**
	 * Persist a previously saved Mngtdc entity and return it or a copy of it to
	 * the sender. A copy of the Mngtdc entity parameter is returned when the
	 * JPA persistence mechanism has not previously been tracking the updated
	 * entity. This operation must be performed within the a database
	 * transaction context for the entity's data to be permanently saved to the
	 * persistence store, i.e., database. This method uses the
	 * {@link javax.persistence.EntityManager#merge(Object) EntityManager#merge}
	 * operation.
	 * 
	 * <pre>
	 * EntityManagerHelper.beginTransaction();
	 * entity = IMngtdcDAO.update(entity);
	 * EntityManagerHelper.commit();
	 * </pre>
	 * 
	 * @param entity
	 *            Mngtdc entity to update
	 * @returns Mngtdc the persisted Mngtdc entity instance, may not be the same
	 * @throws RuntimeException
	 *             if the operation fails
	 */
	public Mngtdc update(Mngtdc entity);

	public Mngtdc findById(MngtdcId id);

	/**
	 * Find all Mngtdc entities with a specific property value.
	 * 
	 * @param propertyName
	 *            the name of the Mngtdc property to query
	 * @param value
	 *            the property value to match
	 * @return List<Mngtdc> found by query
	 */
	public List<Mngtdc> findByProperty(String propertyName, Object value);

	public List<Mngtdc> findByTdcnombre(Object tdcnombre);

	public List<Mngtdc> findByTdcnumerar(Object tdcnumerar);

	public List<Mngtdc> findByTdcnumero(Object tdcnumero);

	public List<Mngtdc> findByTdcexterno(Object tdcexterno);

	public List<Mngtdc> findByTdcbodegas(Object tdcbodegas);

	public List<Mngtdc> findByTdcagrega(Object tdcagrega);

	public List<Mngtdc> findByTdcedita(Object tdcedita);

	public List<Mngtdc> findByTdcelimina(Object tdcelimina);

	public List<Mngtdc> findByTdcreabre(Object tdcreabre);

	public List<Mngtdc> findByTdcconsult(Object tdcconsult);

	public List<Mngtdc> findByTdcimprime(Object tdcimprime);

	public List<Mngtdc> findByTdcprecata(Object tdcprecata);

	public List<Mngtdc> findByTdcactivo(Object tdcactivo);

	/**
	 * Find all Mngtdc entities.
	 * 
	 * @return List<Mngtdc> all Mngtdc entities
	 */
	public List<Mngtdc> findAll();
}